<?php
/**
 * Created by PhpStorm.
 * User: Jerry
 * Date: 2017/4/28
 * Time: 16:53
 */

namespace SDXApi\Model;


use Think\Model;

/**
 * Class AlbumTemplateCategoryModel
 * @package SDXApi\Model
 */
class AlbumTemplateCategoryModel extends Model
{
    /**
     * @var string
     */
    protected $tableName = 'album_template_category';

    /**
     * Created by Jerry
     * @param int $id
     * @return mixed
     */
    public function findCategoryByTemplateId($id = 0)
    {
        $where = array(
            'template_id'	=>	$id,
        );

        return $this->where($where)->find();
    }
}